screen navigation:
    modal False
    window:
        style 'gm_root'
    frame:
        xalign 0.5
        yalign 1.0
        ypadding 4
        xminimum 1.0
        background None
        hbox:
            xalign 0.5
            spacing 2
            textbutton _('返回'):
                action Return()
                xminimum 128
            textbutton _('选项'):
                action ShowMenu('preferences')
                xminimum 128
            textbutton (_('保存游戏')):
                action ShowMenu('save')
                xminimum 128
            textbutton (_('载入存档')):
                action ShowMenu('load')
                xminimum 128
            textbutton (_('删除存档')):
                action ShowMenu('delete')
                xminimum 128
            textbutton (_('主菜单')):
                action MainMenu()
                xminimum 128
            textbutton _('退出'):
                action Quit()
                xminimum 128

init -2:
    $ style.gm_nav_button.size_group = "gm_nav"
screen file_picker:
    modal False
    frame:
        xalign 0.5
        ymaximum 500
        ypadding 0
        background None
        xpadding 15
        ycenter 0.5
        vbox:
            spacing 0
            hbox:
                spacing 3
                xcenter 0.5
                textbutton _('上一页'):
                    action FilePagePrevious()
                    xminimum 120
                    yminimum 45
                textbutton _('自动'):
                    action FilePage('auto')
                    xminimum 120
                    yminimum 45
                for i in range(1, 9):
                    textbutton str(i):
                        xmargin 0
                        xpadding 32
                        yminimum 45
                        action FilePage(i)
                textbutton _('下一页'):
                    action FilePageNext()
                    xminimum 120
                    yminimum 45
            $ columns = 3
            $ rows = 2
            null:
                height 10
            grid columns rows:
                transpose False
                spacing 1
                xalign 0.5
                for i in range(1, ((columns * rows) + 1)):
                    button:
                        ypadding 3
                        xpadding 0
                        xminimum 254
                        background Solid('#0007')
                        yminimum 260
                        action (If((renpy.get_screen('delete') == None), FileAction(i), FileDelete(i)))
                        hover_background Solid('#0009')
                        vbox:
                            xcenter 0.5
                            frame:
                                ypadding 8
                                background None
                                xpadding 10
                                add FileScreenshot(i)
                            $ description = ('% 2s. %s\n%s' % (FileSlotName(i, (columns * rows)), FileTime(i, empty=_('空的存档')), FileSaveName(i)))
                            null:
                                height -6
                            text description:
                                xalign 0.5
                                text_align 0.5
                            key 'save_delete':
                                action FileDelete(i)
            null:
                height 2

screen save:
    tag menu
    modal False
    use navigation
    frame:
        ymaximum 32
        bottom_padding 10
        ypadding 0
        xcenter 0.5
        ypos -10
        xminimum 1024
        background None
        xpadding 0
        ymargin 0
        text ('保存游戏'):
            xalign 0.5
            style 'tip'
            size 64
    use file_picker

screen load:
    tag menu
    modal False
    use navigation
    frame:
        ymaximum 32
        bottom_padding 10
        ypadding 0
        xcenter 0.5
        ypos -10
        xminimum 1024
        background None
        xpadding 0
        ymargin 0
        text ('加载存档'):
            xalign 0.5
            style 'tip'
            size 64
    use file_picker

screen delete:
    tag menu
    modal False
    use navigation
    frame:
        ymaximum 32
        bottom_padding 10
        ypadding 0
        xcenter 0.5
        ypos -10
        xminimum 1024
        background None
        xpadding 0
        ymargin 0
        text ('删除存档'):
            xalign 0.5
            style 'tip'
            size 64
    use file_picker

screen preferences:
    tag menu
    modal False
    use navigation
    grid 3 1:
        style_group 'prefs'
        vbox:
            frame:
                style_group 'pref'
                vbox:
                    label _('显示')
                    null:
                        height 10
                    textbutton _('窗口模式'):
                        action (Preference('display', 'window'))
                    textbutton _('全屏模式'):
                        action (Preference('display', 'fullscreen'))
            frame:
                style_group 'pref'
                vbox:
                    label _('场景过渡')
                    null:
                        height 10
                    textbutton _('全部'):
                        action (Preference('transitions', 'all'))
                    textbutton _('无过渡'):
                        action (Preference('transitions', 'none'))
        vbox:
            frame:
                style_group 'pref'
                vbox:
                    label (_('文字速度'))
                    bar:
                        value (Preference('text speed'))
            frame:
                style_group 'pref'
                vbox:
                    label _('跳过')
                    textbutton (_('已阅信息')):
                        action (Preference('skip', 'seen'))
                    textbutton (_('所有信息')):
                        action (Preference('skip', 'all'))
            frame:
                style_group 'pref'
                vbox:
                    label (_('选择之后'))
                    textbutton (_('停止跳过')):
                        action (Preference('after choices', 'stop'))
                    textbutton (_('继续跳过')):
                        action (Preference('after choices', 'skip'))
        vbox:
            frame:
                style_group 'pref'
                vbox:
                    label (_('自动前进时长'))
                    bar:
                        value (Preference('auto-forward time'))
            frame:
                style_group 'pref'
                vbox:
                    label (_('音乐音量'))
                    bar:
                        value (Preference('music volume'))
            frame:
                style_group 'pref'
                vbox:
                    label (_('音效音量'))
                    bar:
                        value (Preference('sound volume'))
                    null:
                        height 10
                    textbutton '测试':
                        action (Play('sound', 'snd/quest.ogg'))
            frame:
                style_group 'pref'
                vbox:
                    label (_('语音音量'))
                    bar:
                        value (Preference('voice volume'))
                    null:
                        height 10
                    textbutton '测试':
                        action (Play('voice', 'voices/Success_03.ogg'))

init:
    python:
        
        style.gm_nav_button.size_group = "gm_nav"
        style.pref_frame.xfill = True
        style.pref_frame.xmargin = 5
        style.pref_frame.top_margin = 5
        style.pref_frame.xmaximum=300
        style.pref_vbox.xfill = True
        
        style.pref_button.size_group = "pref"
        style.pref_button.xalign = 1.0
        
        
        style.pref_slider.xmaximum = 192
        style.pref_slider.xalign = 1.0
        
        style.soundtest_button.xalign = 1.0
screen yesno_prompt:
    modal True
    frame:
        ymaximum 128
        style 'window'
        xmargin 0.02
        xfill True
        ypadding 0.1
        ycenter 0.5
        vbox:
            xalign 0.5
            spacing 5
            yalign 0.5
            text _(message):
                xalign 0.5
            hbox:
                xalign 0.5
                spacing 25
                textbutton _('是'):
                    action yes_action
                    xminimum 200
                    yminimum 48
                textbutton _('否'):
                    action no_action
                    xminimum 200
                    yminimum 48